-----------------------------------------------------------------------------
-- 宽屏左右黑框，fgui最上层
--
---------------
-- Author:
-- Date: 2021.10.30
-----------------------------------------------------------------------------
require "Common/define"
require "Logic/Config"
require "Logic/ZZMathBit"

UICover = UIBase.New(PanelResNames.UICover)
local this = UICover


function UICover.Init()
    UIBase.Init(this)
end

function UICover:OnCreate()
    print("打开黑边界面")
    self.uiCream = GameObject.Find("Stage Camera"):GetComponent("Camera")
    self.uiCream.cullingMask = ZZMathBit.orOp( ZZMathBit.lShiftOp(1, LayerMask.NameToLayer("Video")) , ZZMathBit.lShiftOp(1, LayerMask.NameToLayer("UI")) )

    self.fguiObj.displayObject.layer = LayerMask.NameToLayer("Video")

end

function UICover:OnDisable()
    print("关闭黑边界面")
end


return UICover;